// Decompiled by GOOSIN CO,LTD Copyright 2010 Pavel Kouznetsov.
// home page: http://www.Goosin.net
// Decompiler options: packimports(3) fieldsfirst ansi space 
// Source File Name:   DealWithString.java

package include.nseer_cookie;

import javax.servlet.ServletContext;

// Referenced classes of package include.nseer_cookie:
//			counter

public class DealWithString
{

	private static String s;
	private static String ss[] = {
		"", ""
	};
	private ServletContext dbApplication;

	public DealWithString(ServletContext dbApplication)
	{
		this.dbApplication = dbApplication;
	}

	public String joinIn(String a, String b)
	{
		counter count = new counter(dbApplication);
		int filenum = count.read("ondemand1", "erpAttachmentcount");
		count.write("ondemand1", "erpAttachmentcount", filenum);
		s = (new StringBuilder(String.valueOf(a))).append(filenum).append(b).toString();
		return s;
	}

	public String[] divide(String c, int k)
	{
		counter count = new counter(dbApplication);
		String filenum = (new StringBuilder(String.valueOf(count.read("ondemand1", "erpAttachmentcount")))).toString();
		ss[0] = "";
		ss[1] = "";
		if (!c.equals(""))
		{
			ss[0] = c.substring(0, k);
			ss[1] = c.substring(k + filenum.length());
		}
		return ss;
	}

}
